home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-02 / map100p.zip / MAP.DOC < prev    next >
Text File  |  1991-11-02  |  8KB  |  249 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.          ╔══════════════════════════════════════════════════════════╗
  15.          ║                           M A P                          ║
  16.          ║               A Turbo Pascal ver 6.0 TPU Unit            ║
  17.          ║                                                          ║
  18.          ║             Copyrighted (C) John H. Gohde, 1991          ║
  19.          ║                    All Rights Reserved                   ║
  20.          ║                                                          ║
  21.          ║          FreeWare licensed for NON-Commercial use.       ║
  22.          ╚══════════════════════════════════════════════════════════╝
  23.  
  24.     Page 1                                                       11-02-91
  25.  
  26.  
  27.      INTRODUCTION
  28.  
  29.           MAP is  a Turbo Pascal  version 6.0 Unit  that provides
  30.           support for limited bit and nibble mapping functions on
  31.           words and bytes.
  32.  
  33.           This is a FreeWare unit that comes complete with Source
  34.           Code.
  35.  
  36.           This  is the  unit that  is required  by ALPHA  version
  37.           1.00.
  38.  
  39.           The  enclosed MAP  unit requires  Turbo Pascal  version
  40.           6.0, which is not included.
  41.  
  42.  
  43.      COPYRIGHT NOTICE
  44.  
  45.           Both the software and its documentation are copyrighted
  46.           materials.  I  reserve  all  rights  to these materials
  47.           under  United  States  law  and international copyright
  48.           conventions  which  are  not  expressly  granted to the
  49.           user.  No part  of this  material may  be reproduced or
  50.           modified in any way without my prior, expressed written
  51.           permission. This  document is NOT Public  Domain. It is
  52.           intended  as an  informational document  for evaluative
  53.           purposes and for use by Registered users. This Document
  54.           may be copied in whole for that intent only.
  55.  
  56.  
  57.      DISCLAIMER
  58.  
  59.           I EXPRESSLY  DISCLAIM ALL WARRANTIES  INCLUDING BUT NOT
  60.           LIMITED TO  THE WARRANTIES OF FITNESS  FOR A PARTICULAR
  61.           PURPOSE AND MERCHANTABILITY. YOU  USE BOTH THE SOFTWARE
  62.           AND DOCUMENTATION AT YOUR OWN RISK!
  63.  
  64.  
  65.      LICENSE
  66.  
  67.           I grant all users of  this software and documentation a
  68.           limited  license  for  their  own private noncommercial
  69.           use.  I  expressly  forbid  any  user  from  making any
  70.           changes to either the software or documentation or from
  71.           profiting from its distribution.
  72.  
  73.           I grant  all BBS's and software  distributors the right
  74.           to  distribute this  software and  to charge  a maximum
  75.           distribution fee of $5.00.
  76.  
  77.     Page 2                                                       11-02-91
  78.  
  79.  
  80.      TRADEMARKS
  81.  
  82.           Turbo  Pascal  and  all   other  Borland  products  are
  83.           trademarks   or   registered   trademarks   of  Borland
  84.           International,  Inc..  Portions  of  the enclosed Turbo
  85.           Pascal unit(s) are Copyrighted (C) 1983,1990 by Borland
  86.           International  as  it/they  were  compiled  with  Turbo
  87.           Pascal.
  88.  
  89.           Any  other brand  or products  names mentioned  in this
  90.           document  are  trademarks  or  registered trademarks of
  91.           their respective holders.
  92.  
  93.  
  94.      BACKGROUND INFORMATION
  95.  
  96.  
  97.           This unit  provides the limited bit  and nibble mapping
  98.           functions  required   by  my  ALPHA   unit  distributed
  99.           separatedly in error without this unit.
  100.  
  101.           It  is  being  distributed  as  FreeWare  complete with
  102.           source code, as it will  probably not be supported with
  103.           future updates.
  104.  
  105.     Page 3                                                       11-02-91
  106.  
  107.  
  108.      TYPES
  109.  
  110.           Str16         = string[16];
  111.  
  112.           FlagPos       = 1..16;
  113.           ----------------------
  114.           A flag is defined by me as  the bits of a word; and are
  115.           numbered from left to right.
  116.  
  117.  
  118.           NibblePos     = 1..4;
  119.           ---------------------
  120.           A nibble is  defined by me as half a  byte or 4 bits. A
  121.           word has bytes or four nibbles; which are numbered from
  122.           left to right.
  123.  
  124.  
  125.           Flags         = word;
  126.           ---------------------
  127.           A word which is defined to consist of 16 flags or bits.
  128.  
  129.  
  130.      FUNCTIONS
  131.  
  132.           Function  FlagsOn(F : Flags; NUM : FlagPos): Boolean;
  133.           -----------------------------------------------------
  134.           A function  that tells you  if flag NUM  is turn on  or
  135.           off.
  136.  
  137.  
  138.           Function  GetDoubleByte( VAR DB : word; NUM : NibblePos): byte;
  139.           ---------------------------------------------------------------
  140.           Returns the value of nibble NUM from the word DB.
  141.  
  142.  
  143.           Function  GetHiNibble( DN : byte): byte;
  144.           ----------------------------------------
  145.           Returns the value of the HI nibble in a byte.
  146.  
  147.  
  148.           Function  GetLoNibble( DN : byte): byte;
  149.           ----------------------------------------
  150.           Returns the value of the LO nibble in a byte.
  151.  
  152.  
  153.           Procedure SetDoubleByte( VAR DB : word; NUM : NibblePos; Value: Byte);
  154.           ----------------------------------------------------------------------
  155.           Sets the nibble number NUM to VALUE in the word DB.
  156.  
  157.  
  158.           Procedure SetFlags( VAR F : Flags; NUM : FlagPos; SW: Boolean);
  159.           ---------------------------------------------------------------
  160.           Sets  the Flag  numbered NUM  to the  boolean SW in the
  161.           word F.
  162.  
  163.  
  164.           Function  SetHiNibble( DN,Hi: byte): byte;
  165.           ------------------------------------------
  166.           Sets the HI nibble in byte DN to the value HI.
  167.  
  168.  
  169.           Function  SetLoNibble( DN,Lo: byte): byte;
  170.           ------------------------------------------
  171.           Sets the LO nibble in byte DN to the value LO.
  172.  
  173.  
  174.           Function  SwapNibbles( DN : byte): byte;
  175.           ----------------------------------------
  176.           Swaps the values  of the HI and LO  nibbles in the byte
  177.           DN.
  178.  
  179.     Page 4                                                       11-02-91
  180.  
  181.           Procedure ToggleFlags( VAR F : Flags; NUM : FlagPos);
  182.           -----------------------------------------------------
  183.           Reverses the value of flag NUN in word F.
  184.  
  185.  
  186.           Function  Flags2Str( F: Flags): str16;
  187.           --------------------------------------
  188.           Prints  the  values  of  all  16  flags  in  word  F in
  189.           sequence.
  190.  
  191.  
  192.     Page 5                                                       11-02-91
  193.  
  194.  
  195.      PRODUCT SUPPORT
  196.  
  197.           This product  is supported by the  author via a product
  198.           support  echo  on  a  24  hour  a  day BBS. First, time
  199.           callers  may   download  the  latest   versions  of  my
  200.           products.
  201.  
  202.           You can  contact me by data  phone (8N1 1200/2400 BAUD)
  203.           at:
  204.  
  205.                      ╔═══════════════════════════════╗
  206.                      ║        The FreeBoard BBS      ║
  207.                      ║         (804)744-0744         ║
  208.                      ║          Richmond, Va.        ║
  209.                      ╚═══════════════════════════════╝
  210.  
  211.           The FreeBoard BBS is a  multi-node RBBS-PC board on the
  212.           Fido Net Work with over 400 MEG's of files.
  213.  
  214.           And, of course, you can ask  your SYSOP to FREQ this or
  215.           any  other files  from  this  board with  the following
  216.           info:
  217.  
  218.                1:264/212,The_FreeBoard_BBS,Midlothian_VA,Bill_Hunter,
  219.                1-804-744-0797,9600,CM,XX,LO,HST
  220.  
  221.  
  222.           The support  echo is called LZE-WC.  You arrive at this
  223.           conference from the MAIN menu by joining it as follows:
  224.  
  225.                J
  226.                LZE-WC
  227.  
  228.           The author may also be contacted by writing to:
  229.  
  230.                     JOHN GOHDE
  231.                     MAP
  232.                     P O BOX 17581
  233.                     RICHMOND, VA 23226-7581
  234.  
  235.           If you  expect a response,  be sure to  include  a self
  236.           addressed and stamped return envelop!
  237.  
  238.  
  239.     Page 6                                                       11-02-91
  240.  
  241.  
  242.      UPDATE HISTORY
  243.  
  244.  
  245.  
  246.           VERSION 1.00 -- originally released on 11-02-91
  247.  
  248.  
  249.